<%@ page  contentType="text/html; charset=UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="page" uri="http://www.forten.org/taglib/page"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@ taglib prefix="forten" uri="http://www.forten.org/taglib/forten"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<!-- 日期控件 -->
<script type="text/javascript" src="../scripts/Calendar/Js/calendar.js"></script>
<link type="text/css" rel="stylesheet"
	href="../scripts/Calendar/Css/calendar.css" />
<!-- end -->
<!-- jquery -->
<script type="text/javascript" src="../scripts/jquery-1.6.min.js"></script>
<!-- 验证引擎组件 -->
<script type="text/javascript"
	src="../scripts/validationEngine/jquery.validationEngine-zh_CN.js" charset="utf-8"></script>
<script type="text/javascript"
	src="../scripts/validationEngine/jquery.validationEngine.js" charset="utf-8"></script>
<link href="../scripts/validationEngine/validationEngine.jquery.css" charset="utf-8"
	rel="stylesheet" type="text/css" />
<title>开课信息</title>
<!-- CSS -->
<link type="text/css" rel="stylesheet" href="../styles/css/reset.css">
<link type="text/css" rel="stylesheet" href="../styles/css/index.css">
<script type="text/javascript" src="../scripts/html5.js"></script>
<!-- end -->
</head>
<body>

	<script type="text/javascript">
		//验证引擎初始
		function doSubmit() {

			jQuery("#frm").validationEngine({});
			if ($("#frm").validationEngine('validate')) {
				document.frm.action = "addCourse.jspx";
				document.frm.submit();
			}
		}

		$(document).ready(function() {

		});

	</script>
	<header>
	<div class="headerWrap"></div>
	</header>
	<div class="content">
		<section>
		<div class="rc_b">
			<div class="rc_info">
				<h3>
					<span class="r_title_ico"></span> 新增开课信息(带*为必填部分)
				</h3>
			</div>
			<form:form modelAttribute="addDto" id="frm" name="frm"
				action="addCourse.jspx">
				<table class="rc_tab03" cellspacing="0" cellpadding="0">
					<tbody>
						<tr>
							<th>课程名</th>
							<forten:token name="addCourse" returnUrl="gotoCourseList.jspx"></forten:token>
							<td class="txtLeft"><form:input path="name"
									class="validate[required]" />&nbsp;* 
									
							</td>
						</tr>
						<tr>
							<th>课程简介</th>
							<td class="txtLeft rc_cr" colspan="3"><form:textarea 
									path="courseInfo" cols="80" rows="4" class="validate[required]" />&nbsp;*
							</td>
						</tr>

						<tr>
							<th>课程状态</th>
							<td class="txtLeft"><form:select path="state"
									class="validate[required]">
									<form:option value="1">可选可退</form:option>
									<form:option value="2">可选不可退</form:option>
								</form:select>&nbsp;*</td>
							<th>课程类别</th>
							<td class="rc_cr"><span class="txtLeft"> <form:input
										path="type"  />
							</span></td>
						</tr>
						<tr>
							<th style="width: 20%;">上课时间</th>
							<td class="txtLeft" style="width: 25%;"><form:input path="teachTime"
									class="validate[required]"
									onclick="displayCalendar(this, 'yyyy-mm-dd hh:ii', this, true, '');"
									readonly="true" />&nbsp;*</td>
							<th style="width: 20">上课地点</th>
							<td class="rc_cr" style="width: 35%;"><span class="txtLeft"> <form:input
										path="classroom" class="validate[required]" />
							</span>&nbsp;*</td>
						</tr>
						<tr>
							<th style="width: 20%;">教师</th>
							<td class="txtLeft" style="width: 25%;"><form:input path="teacherName"
									 />&nbsp;*</td>
							<th style="width: 20%;">上课时间描述</th>
							<td class="rc_cr" style="width: 35%;"><span class="txtLeft"> <form:input
										path="teachTimeDescription"  />
							</span></td>
						</tr>

						<tr>
							<th>教师简介</th>
							<td class="txtLeft rc_cr" colspan="3"><form:textarea cols="80" rows="4"
									path="teacherInfo" class="validate[required]" />&nbsp;*</td>
						</tr>
						<tr>
							<th>带班班主任姓名</th>
							<td class="txtLeft"><form:input path="headTeacherName"
									 /></td>
							<th>带班班主任邮件地址</th>
							<td class="rc_cr"><span class="txtLeft"> <form:input
										path="headTeacherEmail" class="validate[custom[email]]" />
							</span></td>
						</tr>

						<tr>
							<th>带班班主任手机</th>
							<td class="txtLeft">
							 <form:input path="headTeacherPhone" class="validate[custom[phone]]"/>
							</td>
							<th>学时</th>
							<td class="rc_cr"><span class="txtLeft"> <form:input maxlength="3" size="3"
								onkeyup="this.value=this.value.replace(/\D/g,'')"
										path="credit" class="validate[required]" />
							</span>&nbsp;*</td>
						<tr>
							<th>课容量</th>
							<td class="txtLeft"><form:input path="classCapacity" maxlength="3" size="3"
								onkeyup="this.value=this.value.replace(/\D/g,'')"
									class="validate[required]" />&nbsp;*</td>
						</tr>
						<tr>
							<th>其他说明</th>
							<td class="txtLeft rc_cr" colspan="3"><form:textarea
									path="otherInfo" cols="80" rows="4"/></td>
						</tr>
						
						<tr>
							<th>备注</th>
							<td class="txtLeft rc_cr" colspan="3"><form:textarea
									path="memo" cols="80" rows="4"/></td>
						</tr>
					</tbody>
				</table>
			</form:form>
			<div class="auto lh30 txtCenter mb15">
				<a class="btn mt7 mr15" href="#" onclick="doSubmit();"> <span>保存</span>
				</a> <a class="btn mt7" href="showCourseList.jspx"> <span>返回</span>
				</a>
			</div>

		</div>
		</section>
		<!-- cont end -->
	</div>
<%@include file="/common/foot.jsp"%>